package com.syqc.entity

import android.os.Parcelable
import kotlinx.parcelize.Parcelize


/**
 *@Author Jasper
 *@Time   2020/8/17
 *@Desc   Main实体类
 */
@Parcelize
data class MainEntity(
    var titleId: Int=-1,
    var itemList: ArrayList<ListEntity>? = null
) : Parcelable {
    @Parcelize
    data class ListEntity(
        var orderNum: Int = 0,
        var imgId: Int = 0,
        var titleId: Int = 0,
//        var clazz: Class<*>,
        var key: String="",
        var urlLink: String = "",
        var title: String = "",
        var sIconLink: String = "",
        var bIconLink: String = "",
        var isChoose: Boolean = false
    ) : Comparable<ListEntity>, Parcelable {
        override fun compareTo(other: ListEntity): Int {
            return this.orderNum - other.orderNum
        }
    }
}